package _enum;

import java.util.ArrayList;
import java.util.List;

/**
 * @Author: huangya
 * @Date: 2020/08/21
 * @Description:
 *  <E extends MyEnum<E>>：E只能是子类自己或者子类的子类
 *  <E extends MyEnum>：E可以是MyEnum的任何子类
 */
public class MyEnum<E extends MyEnum<E>> {

    List<E> fff(E e){
        List<E> aaa = new ArrayList<>();
        aaa.add(e);
        aaa.getClass().getTypeParameters();
        return aaa;
    }
}
